﻿using UnityEngine.UIElements;
using winS.Unity.Process;

namespace winS.UnityEditor.ProcessEditor
{
    [StepNodeSearchTreeGroup("内置/等待"), Title("等待", "Wait")]
    public class WaitStepNode : GeneralStepNode<WaitStep>
    {
        protected internal override void OnCreated()
        {
            Add(CreateDurationField());
        }

        private VisualElement CreateDurationField()
        {
            return guiFactory.CreateFloatField("等待时间:", step.duration, newValue => step.duration = newValue);
        }
    }
}